fix assist to commit
authorJoey Hess <joeyh@joeyh.name>
Thu, 18 May 2023 18:50:05 +0000 (14:50 -0400)
committerJoey Hess <joeyh@joeyh.name>
Thu, 18 May 2023 18:50:05 +0000 (14:50 -0400)
Command/Assist.hs
Command/Sync.hs

index 1ec83c13393b0460e7aeb5b8bd167db0752f05c7..aaa8ea03765723d5a690754729b9ab919218bde0 100644 (file)
@@ -34,10 +34,4 @@ myseek o = startConcurrency transferStages $ do
                }
        
        Command.Sync.prepMerge
-       Command.Sync.seek' o'
-  where
-       o'
-               | Command.Sync.contentOption o == Nothing 
-                       && Command.Sync.noContentOption o == Nothing =
-                               o { Command.Sync.contentOption = Just True }
-               | otherwise = o
+       Command.Sync.seek' o
index 970fc39007898a425caa98636b60e6466d8858b3..d6815618e56398044ddecb1c03c57cf93ce5d11e 100644 (file)
@@ -152,10 +152,14 @@ optParser mode desc = SyncOptions
                ( long "not-only-annex"
                <> help "operate on git branches as well as annex"
                )
-       <*> unlessmode [SyncMode] False (switch
-               ( long "commit"
-               <> help "commit changes to git"
-               ))
+       <*> case mode of
+               SyncMode -> switch
+                       ( long "commit"
+                       <> help "commit changes to git"
+                       )
+               PushMode -> pure False
+               PullMode -> pure False
+               AssistMode -> pure True
        <*> unlessmode [SyncMode] True (switch
                ( long "no-commit"
                <> help "avoid git commit"